package edu.xmut.decorator.example;

/**
 * 相当于Decorator类
 * @author 朔风
 * @date 2024-02-27 17:53
 */
public class Finery implements ICharacter {

    protected ICharacter component;

    public void decorate(ICharacter component) {
        this.component = component;
    }

    @Override
    public void show() {
        if (component != null) {
            component.show();
        }
    }
}
